package com.shph.validation.rule;

import lombok.AllArgsConstructor;
import lombok.Data;

@Data
@AllArgsConstructor
public class RuleEntity {
    // 属性名称
    String fiedName;

    // 额外的参数
    String refValue;

    // 错误信息
    String errorMsg;

    /**
     * 可以是 IRule | Validator.Strategy枚举 | String(IRule全限定此名称)
     */
    Object rule;

    public RuleEntity(String fiedName, String errorMsg, Object rule) {
        this.fiedName = fiedName;
        this.errorMsg = errorMsg;
        this.rule = rule;
    }
}
